#!/bin/bash

# Test object cache reclaim at startup

. ./common

for i in `seq 0 2`; do
    _start_sheep $i "-w size=30M"
done

_wait_for_sheep 3

_cluster_format -c 1

$DOG vdi create test 20M
_random | $DOG vdi write -w test

$DOG cluster shutdown
_wait_for_sheep_stop

#trigger an object reclaim at startup
for i in `seq 0 2`; do
    _start_sheep $i "-w size=10M"
done

_wait_for_sheep 3
